import socket

class WordSender:
    def __init__(self,addr,port):
        self.s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
        self.addr = addr
        self.port = port
        self.s.connect((addr,port))
    
    def sendWord(self,word):
        self.s.send(word.encode('utf-8'))


if __name__ == '__main__':
    myWordSender = WordSender("192.168.0.4",913)
    myWordSender.sendWord("123")